import request from "@/utils/request";
import { parseStrEmpty } from "@/utils/ruoyi";

// 下游产品企微配置产品新增、编辑
export function addOrEdit(data) {
  return request({
    url: "/down/weChatConfig/v1.0.0/addOrEdit",
    method: "post",
    data: data,
  });
}

// 下游产品企微配置产品删除
export function deleteById(id) {
  return request({
    url: "/down/weChatConfig/v1.0.0/deleteById",
    method: "get",
    params: {
      id: parseStrEmpty(id),
    },
  });
}
// 下游产品企微采量-查询计费模式
export function getFeeType() {
    return request({
      url: '/down/weChatConfig/v1.0.0/getFeeType',
      method: 'get',
    })
  }
// 下游产品企微采量-查询采量模式
export function getPickType() {
    return request({
      url: '/down/weChatConfig/v1.0.0/getPickType',
      method: 'get',
    })
  }
// 下游产品企微配置产品详情查询
export function queryById(id) {
    return request({
      url: '/down/weChatConfig/v1.0.0/queryById',
      method: 'get',
      params: { 
        id:parseStrEmpty(id)
      }
    })
  }

// 下游产品企微配置产品分页查询
export function queryDownWeChatConfigByPage(data) {
  return request({
    url: "/down/weChatConfig/v1.0.0/queryDownWeChatConfigByPage",
    method: "post",
    data: data,
  });
}
